package com.joker.config;

import io.gitee.guoguoleo.handler.MetaHandler;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.time.LocalDateTime;

@Slf4j
@Component
public class ObjMetaHandler extends MetaHandler {

    @Override
    public void startInsertHandler() {
        log.info("insert初始化");
        this.setInsertHandler("createTime", LocalDateTime.class, LocalDateTime.now());
    }

    @Override
    public void startUpdateHandler() {
        log.info("update初始化");
        this.setUpdateHandler("updateTime", LocalDateTime.class, LocalDateTime.now());
    }
}
